home *** CD-ROM | disk | FTP | other *** search
- program CGI;
- {$APPTYPE CONSOLE}
- uses
- DrBobCGI, SysUtils, Classes, IniMod;
- var
- Notes: TStringList = nil;
- User, Password: String;
- Get: Boolean;
- i: Integer;
- begin
- writeln('Content-type: text/plain');
- writeln;
- User := Value('User');
- Password := Value('Password');
- Notes := TStringList.Create;
- Get := Value('Notes') = '';
- if not Get then Notes.Text := Value('Notes');
- try
- try
- if Get then
- begin
- GetLines(User,Password,Notes);
- for i:=1 to Notes.Count do writeln(Notes[Pred(i)])
- end
- else
- begin
- SetLines(User,Password,Notes);
- writeln('OK')
- end
- except
- on E: Exception do writeln(E.Message)
- end
- finally
- Notes.Free
- end
- end.
-